package com.lb.spring.demo.service.impl;

import com.lb.spring.demo.service.IModifyService;
import com.lb.spring.framework.annotation.LbService;

/**
 * 增删改业务
 * @author Tom
 *
 */
@LbService
public class ModifyService implements IModifyService {

	/**
	 * 增加
	 */
	@Override
    public String add(String name, String addr) throws Exception {
        throw new Exception("故意抛出异常，测试切面通知是否生效");
//		return "modifyService add,name=" + name + ",addr=" + addr;
	}

	/**
	 * 修改
	 */
	@Override
    public String edit(Integer id, String name) {
		return "modifyService edit,id=" + id + ",name=" + name;
	}

	/**
	 * 删除
	 */
	@Override
    public String remove(Integer id) {
		return "modifyService id=" + id;
	}

}
